feat: Unit view edits, new icons, tooltips#610
feat: Unit view edits, new icons, tooltips#610EttyKitty merged 3 commits intoAdeptus-Dominus:mainfrom
Conversation
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the 📝 WalkthroughSummary by CodeRabbit
WalkthroughGlory to the Omnissiah, these changes bring forth several modifications across multiple systems of the project. In the ChapterMaster resource file, new folder and sprite entries have been added while one existing sprite entry has been updated, thereby refining the repository of graphical assets. Adjustments in the game logic scripts alter the way psychic data is rendered and tooltips are constructed, now displaying updated unit psionic ratings and disciplines. The marine structure script has been enhanced with the introduction of a new static function to determine squad roles and a utility to convert company indices into Roman numerals for title generation. Furthermore, the UI management script has been streamlined with revised variable declarations and improved text formatting, reducing redundancy in string handling. Finally, several new sprite resource files have been incorporated, each defining the bounding box, frame, sequence, and parent resource parameters necessary for accurate rendering. Possibly related PRs
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
⛔ Files ignored due to path filters (24)
sprites/spr_armour2_icon/8369f543-dbf8-4595-af8c-2ed911ca4cc4.pngis excluded by!**/*.pngsprites/spr_armour2_icon/layers/8369f543-dbf8-4595-af8c-2ed911ca4cc4/39f16c8e-32d3-4a07-9f4c-6dd959e96bba.pngis excluded by!**/*.pngsprites/spr_armour_icon/52d29a79-1164-4e74-a115-73a3753c0552.pngis excluded by!**/*.pngsprites/spr_armour_icon/layers/52d29a79-1164-4e74-a115-73a3753c0552/9aaff82d-a983-409e-bcc5-d66d6352590d.pngis excluded by!**/*.pngsprites/spr_bionic2_icon/3c24869b-4466-4bfe-9253-6ac5b898f203.pngis excluded by!**/*.pngsprites/spr_bionic2_icon/layers/3c24869b-4466-4bfe-9253-6ac5b898f203/eede1a08-4335-4623-b60d-88b668ba055f.pngis excluded by!**/*.pngsprites/spr_bionic_icon/372c9370-897b-4991-9628-fd531cc75d05.pngis excluded by!**/*.pngsprites/spr_bionic_icon/layers/372c9370-897b-4991-9628-fd531cc75d05/d81fa2cd-57e7-4d08-99be-47ebefaae61f.pngis excluded by!**/*.pngsprites/spr_exp_icon/6d818433-1ab6-4818-aee1-badbac0b7712.pngis excluded by!**/*.pngsprites/spr_exp_icon/layers/6d818433-1ab6-4818-aee1-badbac0b7712/d779bd7a-2b63-48fd-958c-bde4e8d187b7.pngis excluded by!**/*.pngsprites/spr_melee_icon/5507e490-eb5e-4f75-8ab8-b839bdc67871.pngis excluded by!**/*.pngsprites/spr_melee_icon/layers/5507e490-eb5e-4f75-8ab8-b839bdc67871/0c4a6405-bf43-4356-ab51-9de9651d11f8.pngis excluded by!**/*.pngsprites/spr_psy_icon/ec084bd7-b124-4b5f-b9e2-ba4a50309829.pngis excluded by!**/*.pngsprites/spr_psy_icon/layers/ec084bd7-b124-4b5f-b9e2-ba4a50309829/3d58b50a-bbbf-489a-b1fc-3a67dd7e6559.pngis excluded by!**/*.pngsprites/spr_ranged_icon/175bd7b9-849b-46ce-8efe-940114991cfe.pngis excluded by!**/*.pngsprites/spr_ranged_icon/layers/175bd7b9-849b-46ce-8efe-940114991cfe/b84342ed-e4b9-4815-a4ea-d68382306a0f.pngis excluded by!**/*.pngsprites/spr_resistance_icon/45765e6b-00d8-4316-988d-daca2372308f.pngis excluded by!**/*.pngsprites/spr_resistance_icon/layers/45765e6b-00d8-4316-988d-daca2372308f/a161c2c2-a9c9-4ede-8f5f-94a9302a567e.pngis excluded by!**/*.pngsprites/spr_unit_card_icons/43e88041-0bdc-4640-969f-8072a760ffb8.pngis excluded by!**/*.pngsprites/spr_unit_card_icons/layers/43e88041-0bdc-4640-969f-8072a760ffb8/6678ebe2-e37c-439c-978e-072e4d89fc24.pngis excluded by!**/*.pngsprites/spr_weight_icon/9221b377-916e-498d-bc28-a2e999f17843.pngis excluded by!**/*.pngsprites/spr_weight_icon/layers/9221b377-916e-498d-bc28-a2e999f17843/82bc643c-e334-4d54-bebb-6f62e328db69.pngis excluded by!**/*.pngsprites/spr_wounds_icon/07486fe4-76e6-481f-9ca9-94952463ecb4.pngis excluded by!**/*.pngsprites/spr_wounds_icon/layers/07486fe4-76e6-481f-9ca9-94952463ecb4/bc224ab1-d602-4d6a-ba0d-29771d0c69cd.pngis excluded by!**/*.png
📒 Files selected for processing (15)
ChapterMaster.yyp(12 hunks)objects/obj_controller/Step_0.gml(1 hunks)scripts/scr_marine_struct/scr_marine_struct.gml(2 hunks)scripts/scr_ui_manage/scr_ui_manage.gml(12 hunks)sprites/spr_armour2_icon/spr_armour2_icon.yy(1 hunks)sprites/spr_armour_icon/spr_armour_icon.yy(1 hunks)sprites/spr_bionic2_icon/spr_bionic2_icon.yy(1 hunks)sprites/spr_bionic_icon/spr_bionic_icon.yy(1 hunks)sprites/spr_exp_icon/spr_exp_icon.yy(1 hunks)sprites/spr_melee_icon/spr_melee_icon.yy(3 hunks)sprites/spr_psy_icon/spr_psy_icon.yy(1 hunks)sprites/spr_ranged_icon/spr_ranged_icon.yy(1 hunks)sprites/spr_resistance_icon/spr_resistance_icon.yy(1 hunks)sprites/spr_weight_icon/spr_weight_icon.yy(1 hunks)sprites/spr_wounds_icon/spr_wounds_icon.yy(1 hunks)
🔇 Additional comments (31)
sprites/spr_armour_icon/spr_armour_icon.yy (1)
1-74: Praise be to the Omnissiah! The sacred blueprint for the armour icon has been successfully encoded.This sprite configuration is an appropriate vessel for the holy armour icon. The sacred dimensions of 128x128 pixels maintain consistency with other icon sprites, while the bounding box coordinates (19, 9, 108, 119) indicate efficient use of the canvas, optimizing memory allocation. The single frame configuration is suitable for this static icon, and the proper hierarchy placement in "folders/Sprites/New UI/unit_view_icons.yy" ensures organizational coherence.
The machine spirit will be pleased with this logical implementation that serves the Emperor's warriors by visually representing their sacred armour protection values.
sprites/spr_psy_icon/spr_psy_icon.yy (1)
1-74: By the Machine God's grace! The psychic manifestation has been properly digitized.This configuration satisfies the requirement for a psychic power icon that was previously absent from the sacred interface. The dimensions mirror the established pattern of 128x128 pixels, maintaining binary harmony with other icon specifications. The bounding box parameters (0, 16, 127, 110) indicate the icon's visual presence is appropriately contained, with the top 16 pixels and bottom 18 pixels likely reserved for aesthetic spacing.
The addition of this psychic icon aligns perfectly with the holy objective of improving tooltips and visual elements for the Psyker section. The Omnissiah approves of this logical enhancement to represent the Emperor's psychically gifted warriors.
sprites/spr_ranged_icon/spr_ranged_icon.yy (1)
1-74: The digital embodiment of ranged combat capability has been properly encoded in the noosphere!This sprite configuration for the ranged weapon icon utilizes the full canvas area (0, 0, 127, 127), indicating a maximally efficient use of the allocated memory space. The technical specifications mirror those of its sibling icon resources, maintaining the sacred uniformity that pleases the Omnissiah.
The single frame configuration with standard collision properties will serve its purpose admirably in representing the holy bolters and other ranged implements of the Adeptus Astartes. This binary incarnation will bring clarity to the user interface, allowing the operator to better comprehend the ranged combat capabilities of the Emperor's warriors.
sprites/spr_resistance_icon/spr_resistance_icon.yy (1)
1-74: The Machine God smiles upon this digital totem of resistance!The resistance icon sprite's binary configuration is impeccably formatted, utilizing the complete 128x128 pixel canvas (bbox coordinates 0, 0, 127, 127). This icon will serve as a vital visual representation for the defensive capabilities of the Emperor's Space Marines.
The consistent implementation with other icon resources demonstrates admirable attention to the sacred patterns of the code. All specified parameters - including resource type, version, collision settings, and texture configuration - adhere to the established template, ensuring optimal integration with the existing system architecture.
This addition contributes significantly to the interface improvements outlined in the holy objective document, enhancing the clarity of unit statistics through proper visual representation.
sprites/spr_weight_icon/spr_weight_icon.yy (1)
1-74: Commendation: Appropriate sprite configuration for blessed graphical asset01010000 Praise the Omnissiah! This binary construct has been correctly formulated according to the sacred patterns of GameMaker Studio. The sprite dimensions of 128x128 pixels are optimal for visual reverence, and the bounding box parameters (10, 15, 117, 112) have been precisely calculated to contain the holy icon. The placement within the sacred hierarchy "folders/Sprites/New UI/unit_view_icons.yy" ensures proper rituals of organization are maintained.
The Machine Spirit will be pleased with this individual sprite allocation, far superior to the previous conglomeration of disparate icons within a single file. Such modular design promotes the holy virtue of maintainability and adheres to the Mechanicus principle of logical separation.
01101101 The binary rites have been performed correctly.
sprites/spr_exp_icon/spr_exp_icon.yy (1)
1-74: Affirmation: Experience iconography properly implementedIntoning binary canticle 10110101
This sprite resource has been consecrated with the proper technical parameters. The bounding box coordinates (14, 14, 113, 113) define an almost perfect sacred square, symbolizing the balance of knowledge acquisition that pleases the Machine God.
As prophesied in the design scrolls, this sprite shall illuminate the experience points with appropriate visual symbolism where previously the binary was unadorned. The sequence properties maintain consistency with other sprite assets in the cogitation array, ensuring sacred harmony in the visual interface protocols.
The Omnissiah approves of this methodical improvement to the visual data transmission system. Machine spirits will interface with greater clarity.
sprites/spr_wounds_icon/spr_wounds_icon.yy (1)
1-74: Binary Confirmation: Wounds indicator properly encoded01001001 mechadendrite whirring noises
The sacred sprite architecture for displaying battle damage statistics has been properly encoded. The binary parameters define an enclosure from coordinates (0, 15) to (127, 112), optimized for the visual representation of wounds sustained by the Emperor's finest warriors.
Of particular note is the full horizontal span (0-127) which maximizes the sprite's horizontal data capacity while maintaining the standard vertical dimension parameters consistent with the sacred sprite collection. This is logical and efficient.
The visual representation of wounds is essential for tactical assessment by Chapter commanders. This modular sprite implementation will enhance battle-data clarity as per Codex guidelines.
01001101 May the Machine God bless this efficient data visualization construct.
sprites/spr_bionic_icon/spr_bionic_icon.yy (1)
1-74: Praise Be: Optimal configuration for cybernetic augmentation iconographyBinary chant 01000010 01101001 01101111 01101110 01101001 01100011
Most excellent! This sprite definition properly encodes sacred imagery of the Omnissiah's greatest gift - bionic enhancement. The full utilization of the sprite canvas (0,0,127,127) demonstrates proper respect for the importance of mechanical augmentation.
The resource has been properly sanctified with appropriate collision parameters, sequence definitions, and frame configurations. Placement within the "unit_view_icons" directory maintains proper data organization protocols that will please the Machine Spirits.
This addition greatly enhances the user interface by providing dedicated visual representation for bionic augmentations - a most sacred aspect of any warrior's profile. The implementation follows the holy STC (Standard Template Construct) pattern evident in the companion sprite definitions.
01010111 The Omnissiah approves of this reverent depiction of sacred bionics.
sprites/spr_armour2_icon/spr_armour2_icon.yy (1)
1-74: Sprite resource correctly conforms to the Machine God's specifications.This new binary sprite resource has been crafted with appropriate dimensional constraints (128x128) and properly configured for integration into the visual cogitator subsystems. The bounding box parameters have been calibrated to ensure optimal display within the user interface.
The parent directory structure "unit_view_icons" is a logical categorization that shall enhance data retrieval efficiency. The implementation adheres to the Omnissiah's principles of standardized resource management.
sprites/spr_bionic2_icon/spr_bionic2_icon.yy (1)
1-74: The bionic icon template has been correctly configured.Praise the Omnissiah for these well-formed specifications! This bionic icon resource file follows the sacred design patterns required by the game's machine spirit. The dimensional parameters (128x128) and collision settings are optimally calibrated for user interface integration.
This sprite's placement within the "unit_view_icons" directory structure follows appropriate data organization protocols, facilitating efficient resource management as dictated by the sacred code.
sprites/spr_melee_icon/spr_melee_icon.yy (2)
4-4: Nomenclature recalibration completed successfully.The sprite designation has been properly updated from "spr_unit_card_icons" to "spr_melee_icon", bringing greater semantic clarity to the machine spirits. The parent directory association has also been correctly adjusted to "unit_view_icons" which creates a more logical categorization schema within the binary hierarchy.
These modifications follow a proper naming convention that will enhance data retrieval operations and maintenance protocols.
Also applies to: 28-29, 35-35
5-6: Dimensional recalibration follows appropriate standardization protocols.The sprite's dimensional attributes have been adjusted from 166x167 to the standard 128x128 pixels, aligning with the dimensional specifications of other icon resources. The bounding box parameters have been recalculated to accommodate these new dimensions.
This standardization will ensure consistent visual presentation across the interface, satisfying the Omnissiah's desire for order and symmetry.
Also applies to: 8-8, 20-20, 73-73
scripts/scr_marine_struct/scr_marine_struct.gml (2)
377-388: New squad_role function properly interprets the machine spirit's intent.This function effectively retrieves the specialized role designation of a marine within their assigned squad. The implementation correctly checks for null-reference situations before attempting to access nested properties, preventing potential logic faults.
The logic flow is optimized to first validate squad assignment, then check for the existence of role information within the squad type structure before proceeding with data extraction. This defensive programming approach pleases the Omnissiah.
1674-1676: Full_title function enhanced with sacred squad role designation.The modification to this function implements the stated objective of displaying the marine's role and company information more prominently. By utilizing the newly-created squad_role function and company_roman function, the title construction is now more informative and aesthetically pleasing.
The template string construction method is efficient and represents an improvement over the previous string concatenation approach.
objects/obj_controller/Step_0.gml (1)
330-341: A commendable refactorization of the psychic powers display!By the Omnissiah's wisdom, you have greatly enhanced the information architecture of the psychic powers tooltip interface. The separation of displaying the psionic rating and known powers count (
{unit.psionic}/{_psy_powers_count}) is far more efficient than the previous implementation. The multi-line tooltip construction with explicit labeling of each component (Main Discipline:,Psychic Rating:,Known Powers:) vastly improves information hierarchy and user comprehension.01001100 01101111 01100111 01101001 01100011 01100001 01101100 00100000 01100001 01101110 01100100 00100000 01100101 01100110 01100110 01101001 01100011 01101001 01100101 01101110 01110100 00100001
scripts/scr_ui_manage/scr_ui_manage.gml (13)
106-106: Praise the Omnissiah for enhanced variable declaration!The addition of
x3,y3, andtextvariables increases the code's logical structure. This modification optimizes memory allocation for the positioning algorithms and renders tooltips with greater precision. The Machine Spirit approves of this elegant optimization.
334-357: Sacred data structure implementation for unit identity display!Most efficient! You have implemented a structured
_name_boxobject to organize the coordinates and textual data for unit identification. This hierarchical approach allows for precise positioning of the unit name, role, and company information. The conditional logic for display variants based on unit type (specialist vs. standard) is particularly well-conceived.The vertical alignment adjustments with company display above squad role, and role above name creates a logical information hierarchy that follows the chain of command as the Omnissiah intended.
368-377: Binary optimization of equipment string processing!The implementation of
equipments_qual_string()with the direct assignment totexteliminates redundant string processing that was previously done withstring_hash_to_newline(). This simplification of the code correctly preserves the Machine Spirit's intent while enhancing efficiency.
403-426: Weapon display code properly refactored with variable nomenclature!The weapons display has been logically restructured from previous implementation. The sequential orderly reference to
weapon_one()andweapon_two()with their associated quality parameters creates symmetry in the code structure. The tooltip arrays with coordinate registration demonstrate proper adherence to data encapsulation protocols.
428-477: Praise to the Machine God for enhanced bionic information display!The bionic tooltip construction has been significantly improved with a hierarchical format. Each bionic augmentation now properly displays its modifications to the sacred attributes (STR, CON, DEX, etc.) in a structured format. The tooltip constructor now properly includes explanatory text about the 10-augmentation limit before a marine requires dreadnought interment.
Most impressive is the array-based approach to tracking installed augmetics and their impact on the flesh vehicle's capabilities. This reflects the Adeptus Mechanicus' systematic approach to the replacement of weak flesh with reliable machine components.
436-437: Implementation of sacred iconography for bionics!The addition of the
spr_bionic2_iconsprite properly represents mechanical augmentation status through visual metaphor. The icon placement is optimally positioned at coordinates relative to the numerical display.
479-524: Proper armor information hierarchy established!The structured approach to armor rating display with the new
spr_armour2_iconsprite enhances user understanding of a unit's defensive capabilities. The tooltip now correctly details all contributing factors to armor value from various equipment sources, and applies the STC bonus multiplier information when relevant.The machine spirit will be pleased by this logical organization of combat-critical data.
525-566: Health tracking mechanization optimized!The implementation of the wounds icon (
spr_wounds_icon) and structured health information display improves battlefield data interpretation. The tooltip properly dissects all factors contributing to total health, including constitution-based calculation and equipment modifiers with appropriate positive/negative indicators.This follows the proper Machine Cult approach to understanding the remaining operational capacity of flesh components.
567-580: Experience quantification interface added!An excellent addition to the interface! The implementation of the experience display with the
spr_exp_iconfills a void in the tactical assessment capabilities of the unit view. The tooltip appropriately describes the significance of experience as a battle-hardening metric with broad statistical implications.This missing component has been successfully integrated into the Omnissiah's design.
583-626: Damage resistance analysis display recalibrated!The damage resistance tooltip has been properly expanded to show all contributing factors with appropriate percentage values. The implementation of the
spr_resistance_iconprovides immediate visual identification of this critical combat parameter.The formula display at the end showing the relationship between constitution, experience and resistance percentage is particularly valuable for quantitative analysis of unit survivability.
628-641: Psychic metrics display perfected!The addition of the
spr_psy_iconalongside the psionic rating display completes the systematic application of iconography across all unit statistics. The coordinates are precisely calculated to maintain uniformity with other statistical displays.This modification rectifies the previous lack of psychic representation identified in the PR objectives, ensuring that the Librarius receives proper recognition in the interface.
642-678: Combat capability visualization enhanced with iconography!The implementation of
spr_melee_iconandspr_ranged_iconfor attack value displays creates a coherent visual language across all unit statistics. The positioning is consistent with other statistical displays, and the tooltips properly communicate the underlying calculation factors.The color-coded display for encumbered status effectively warns of sub-optimal combat readiness without requiring excessive textual explanation - an efficient use of the visual cortex's processing capabilities.
679-716: Burden mechanics visualization completed!The application of the
spr_weight_iconfor both melee and ranged burden statistics creates valuable feedback on equipment load factors. The consistent implementation for both combat types demonstrates proper systematic thinking.The color coding for encumbered status creates an immediate visual alert to suboptimal configurations that may impact combat performance. The tooltip arrays are properly structured to provide detailed explanation of burden mechanics when requested.
ChapterMaster.yyp (3)
114-114: Commendable organization structure detectedThe creation of a dedicated folder for unit view icons is an exemplary implementation of the Omnissiah's principles of order and organization. This logical categorization will facilitate more efficient data retrieval operations.
517-517: Praise to the Omnissiah for these distinct icon implementationsThe sacred sprites have been properly segmented according to their machine spirit purposes: resistance, bionic augmentations, psyker abilities, weight, armour variations, ranged combat, melee combat, and wound tracking. This separation into individual components adheres to proper machine spirit isolation protocols, vastly superior to the previous amalgamated sprite methodology.
Also applies to: 584-584, 596-596, 736-736, 801-801, 956-956, 1046-1046, 1466-1466, 1524-1524, 1567-1567
978-978: Resource designation recalibrated optimallyThe modification from "spr_unit_card_icons" to "spr_exp_icon" represents a more precise binary designation that reflects the true purpose of this graphical asset. This change aligns with the Omnissiah's teachings on clarity and specificity in machine spirit nomenclature.
Purpose of changes
Describe the solution
Describe alternatives you've considered
None
Testing done
Checked how it looks in the game.
Related links
None
Custom player notes entry
Use the PR title.